<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/common/common_tag.jsp"%>
<%@include file="/common/common_js.jsp"%>
<script type="text/javascript">
$(function(){
	initEasyUIStyle();
})
function btn_save (){
	var flag = $('#classRoomForm').form('validate');
	if(flag){
		$.ajax({
   			url: "classRoom_addClassRoom.do",
   			type: "post",
   			data: $("#classRoomForm").serialize(),
   			datatype:"json",
   			success: function(data){
		    	if(data.MSG=="success"){
		    		$.messager.alert('提示','数据已保存!','info');
   			    }else{
   			    	$.messager.alert('提示','数据保存失败!','error');
	   			}
		  	}
		});
   	}
}
</script>
 <div>
	<form id="classRoomForm" method="post">
	<div class="pageForm">	
	<div class="contentTitle">新增教室</div>
			<dl>
				<dt>
					教室名称：
				</dt>
				<dd>
					<input name="room.name" type="text" class="required" />
				</dd>
			</dl>

			<div class="formBar">
				<ul>
					<li>
						<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-save"
							id="btn_save" onclick="btn_save()">提交</a>
							
					</li>
					<li>
						<a href="javascript:void(0)" class="easyui-linkbutton" iconCls="icon-cancel"
							id="btn_cancel">取消</a>
					</li>
				</ul>
			</div>
		</div>
	</form>
		
</div>
